<?php
$this->breadcrumbs=array(
	'Participants'=>array('index'),
	'Create',
);

if(Yii::app()->user->name=='admin')
{
	$this->menu=array(
		array('label'=>'List Participant', 'url'=>array('index')),
		array('label'=>'Manage Participant', 'url'=>array('admin')),
	);
}
?>
<?php
$event=Event::model()->find('E_id=?', array($_GET['id']));
?>
<h1>Sign up for <?php echo $event['E_title']; ?> </h1>

<?php 

$this->widget('zii.widgets.CDetailView', array(
	'data'=>$event,
	'attributes'=>array(
		'E_title',
		'E_subtitle',
		'E_startdate',
		'E_enddate',
		'E_regstartdate',
		'E_regenddate',
		array(
		 'visible'=>empty($event['E_multiparticipant']) ? false : true, 
		 'name'=>'Multiparticipant',
		 'value'=>'Yes'),
		 array(
		 'visible'=>empty($event['E_paidevent']) ? false : true, 
		 'name'=>'Paid Event',
		 'value'=>'Yes'),
		 array(
		 'name'=>'Paid Event',
		 'value'=>empty($event['E_paidevent']) ? 'Free' : '$'.number_format($event['E_amount'],2, '.', ',')
			)
	),
));


//echo $this->renderPartial('//event/view', array('model'=>$event));
echo $this->renderPartial('_form', array('model'=>$model));
?>